BigDFT.TB module

This module enables to compute the electronic properties of a solid state system using the matrices produced by a linear scaling calculation in BigDFT

class TightBinding(sys=<BigDFT.Systems.System object>, d=5)[source]
Defines the tight-binding object associated to

-a system (Systems.System) -an interaction radius (int)

class System(*args, **kwargs)

A system is defined as a named collection of fragments. You can manipulate a system as if it were a standard python dictionary, however it also has helper routines for performing operations on the full system.

matching_index(sys_e, r0_e=None, tol=0.1)[source]

Given two systems, finds the atom indices where the minimal system matches the extended one.

Parameters:
  • sys_e (Systems.System) – the extended system

  • r0_e (3d-array) – the origin of self.sys in sys_e

  • tol (float) – tolerance for matching systems

Returns:

a mapping between the atom indices that maximise the matching, with the associated error

Return type:

(dict)

shell_matrix(sys_e, mat, metadata)[source]

Given a mapping between atom sites and their periodic images, retrieves their matrices from a linear-scaling calculation. The correspondance between the mapping and the run is given by a list of indices.

Parameters:
  • R_sh (dict) – a mapping between atom sites and their periodic

  • images

  • vectors (their difference in cell index and positions) –

  • sys (Systems.System) – the linear-scaling system

  • mat (list) – the sparse matrices, H and S (scipy.sparse.csc_matrix)

  • metadata (Spillage.MatrixMetadata) – the information on the matrices

Returns

H_sh (dict): a mapping between the atom sites, their difference in cell index and their hamiltonian matrix S_sh (dict): idem for overlap matrix

k_path(hsp, n=101)[source]

Given a set of high-symmetry points, finds the corresponding k-path

k_matrix(k, m_sh)[source]

Given a mapping between atom sites and their perdiodic images, their Bravais vectors and their matrix elements, this function computes the k-resolved matrices

Parameters:
  • k (array) – the k-points sampling

  • m_sh (list) – a mapping between the atom sites and matrices

  • idmat (list) – orbitals number per atom

Returns:

The k-resolved matrices and energy spectrum

plot_bs(k, Ek, ax=None)[source]

Given a k-path and its eigenvalues, plot the band structure